#include <stdio.h>
#include <string.h>
/* void my_strcpy(char *arr1, char *arr2)
{
    while (*arr2 != '\0')
    {
        *arr1 = *arr2;
        arr2++;
        arr1++;
    }
    *arr1 = *arr2;
} */
void my_strcpy(char *arr1, char *arr2) // 改进后的代码
{
    while (*arr1++ = *arr2++)
    {
        ;
    }
}
int main()
{
    char arr1[] = "hello bit";
    char arr2[] = "hhhhhhh";
    my_strcpy(arr1, arr2);
    printf("%s\n", arr1);
    printf("%s\n", arr2);
    return 0;
}